﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Site.Master" AutoEventWireup="true" CodeBehind="chitietcuahang.aspx.cs" Inherits="Web.chitietcuahang" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
<div class="list-product">
<div class="header-listproduct">
<h3>Danh Sách Game Trong Shop</h3>
</div>
<div class="content-listproduct">
    
    
    <asp:DataList ID="listproduct" runat="server" RepeatColumns="3" Width="100%" 
        RepeatDirection="Horizontal" DataSourceID="SqlDataSource1">
        <ItemTemplate>
       
            
            
                 <div class="product">
                <div class="imgproduct">
                    <asp:Image ID="Image1" runat="server" ImageUrl='<%# Eval("Image") %>' Width="134px" Height="193px" />
                    </div>
                    <asp:HyperLink ID="HyperLink1" runat="server" CssClass="nameproduct" 
                    NavigateUrl='<%# Eval("ID","~/ChiTietSanPham.aspx?pid={0}") %>' 
                    Text='<%# Eval("Name") %>'></asp:HyperLink>
                </div>
                
           
            
               
            
            
        </ItemTemplate>
    </asp:DataList>
    
    

    <asp:SqlDataSource ID="SqlDataSource1" runat="server" 
        ConnectionString="<%$ ConnectionStrings:ConnectionString %>" 
        SelectCommand="SELECT DetailShop.Id_Product,Product.Id,Product.Image,Product.Name FROM DetailShop, Product WHERE  DetailShop.Id_Shop = @Id AND DetailShop.Id_Product=Product.Id">
        <SelectParameters>
            <asp:QueryStringParameter Name="Id" QueryStringField="sid" Type="Int32" />
        </SelectParameters>
    </asp:SqlDataSource>
    
    <div style="border-top: 2px solid black; margin-top:50px">

    <asp:DataList ID="DataList1" runat="server" DataSourceID="SqlDataSource2">
        <ItemTemplate>
                 <div style=" margin-left: 50px; border-top">
                <div >
               <h3> <asp:Label ID="Label6" runat="server" Text='<%# Eval("ShopName") %>' />  </h3>
              </div>   
              <div >   
            <asp:Label ID="Label4" runat="server" Text='<%# Eval("Address") %>' />
            </div>
            <div style="  float:left">   
           <h4>Tel:</h4>
            </div>
            <div style="  float:left; margin-left:3px">   
            <asp:Label ID="Label5" runat="server" Text='<%# Eval("Tel") %>' />
            </div>
        </div>
        </ItemTemplate>
    </asp:DataList>
    <asp:SqlDataSource ID="SqlDataSource2" runat="server" 
        ConnectionString="<%$ ConnectionStrings:ConnectionString %>" 
        SelectCommand="SELECT [ShopName], [Address], [Tel] FROM [Shop] WHERE Idshop=@Id">
        <SelectParameters>
            <asp:QueryStringParameter Name="Id" QueryStringField="sid" Type="Int32" />
        </SelectParameters>
    </asp:SqlDataSource>
    
    </div>

</div>
   
   
</div>
</asp:Content>
